import axios from 'axios';

//fn1 请求发送成功的回调
//fn2 请求发送失败的回调
axios.interceptors.request.use(
  (config) => {
    // config.url = 'jjj';
    return config;
  },
  (err) => {
    console.log('失败了');
    return err;
  }
);
axios.interceptors.response.use(
  (resp) => {
    return resp.data;
  },
  (err) => {
    console.log('服务器响应失败');
    return err;
  }
);
